import amaret.freestyle.board.Led0;
import amaret.freestyle.board.Led1;
import amaret.freestyle.board.Led2;
import amaret.freestyle.mcu.atmega128.BusyWait;

module Board inherits embios.interfaces.IBoard { 
    
}

##--------

function startup()
{
    for (var Int i = 0; i < 4; i++) {
        Led0.toggle();
        BusyWait.wait(100);
    }
}

function shutdown( stat )
{
    if (stat == -1) { // abort status
        Led2.on();
    }
    else {          // some other status
        Led0.on();
    }
}
